package com.netmarch.entity;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

import io.swagger.annotations.ApiModelProperty;


@Entity
@Table(name="user")
public class User  implements Serializable{
	/**
	 * 
	 */
	private static final long serialVersionUID = -5549412385811787700L;
	@Id
	private int id;
	@ApiModelProperty(value = "用户姓名") 
	private String name;
	@ApiModelProperty(value = "用户唯一标识") 
	private String code;
	@ApiModelProperty(value = "用户密码") 
	private String password;
	private String tel;
	private String email;
	private String url;
	private String infono;
	private String address;
	@Temporal(TemporalType.TIMESTAMP)
	private Date addtime;
	@Temporal(TemporalType.TIMESTAMP)
	private Date edittime;
	private String pass;
	private String passda;
	private int sex;
	
	@ManyToOne
	@JoinColumn(name = "pass", referencedColumnName = "value", insertable = false, updatable = false)
	private Ansdict ansdict ;

	public User() {
		super();
	}

	public User(int id, String name, String code, String password, String tel, String email, String url, String infono,
			String address, Date addtime, Date edittime, String pass, String passda, int sex, Ansdict ansdict) {
		super();
		this.id = id;
		this.name = name;
		this.code = code;
		this.password = password;
		this.tel = tel;
		this.email = email;
		this.url = url;
		this.infono = infono;
		this.address = address;
		this.addtime = addtime;
		this.edittime = edittime;
		this.pass = pass;
		this.passda = passda;
		this.sex = sex;
		this.ansdict = ansdict;
	}

	public int getId() {
		return id;
	}

	public void setId(int id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	public String getTel() {
		return tel;
	}

	public void setTel(String tel) {
		this.tel = tel;
	}

	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	public String getUrl() {
		return url;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	public String getInfono() {
		return infono;
	}

	public void setInfono(String infono) {
		this.infono = infono;
	}

	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public Date getAddtime() {
		return addtime;
	}

	public void setAddtime(Date addtime) {
		this.addtime = addtime;
	}

	public Date getEdittime() {
		return edittime;
	}

	public void setEdittime(Date edittime) {
		this.edittime = edittime;
	}

	public String getPass() {
		return pass;
	}

	public void setPass(String pass) {
		this.pass = pass;
	}

	public String getPassda() {
		return passda;
	}

	public void setPassda(String passda) {
		this.passda = passda;
	}

	public int getSex() {
		return sex;
	}

	public void setSex(int sex) {
		this.sex = sex;
	}

	public Ansdict getAnsdict() {
		return ansdict;
	}

	public void setAnsdict(Ansdict ansdict) {
		this.ansdict = ansdict;
	}

	
	

}
